﻿using System;
using System.Collections.Generic;
using UnityEngine;

// Token: 0x02000282 RID: 642
public class CharMaleClothes : global::CharClothes
{
	// Token: 0x06000FA4 RID: 4004 RVA: 0x00072D1C File Offset: 0x00070F1C
	public CharMaleClothes(global::CharInfo info) : base(info)
	{
		this.maleFile = (this.chaFile as global::CharMaleFile);
		this.maleClothesInfo = (this.clothesInfo as global::CharFileInfoClothesMale);
		this.maleStatusInfo = (this.statusInfo as global::CharFileInfoStatusMale);
	}

	// Token: 0x06000FA5 RID: 4005 RVA: 0x00072D58 File Offset: 0x00070F58
	public override bool AddStateKind(int clothKind, string stateType)
	{
		base.dictStateType.Remove(clothKind);
		byte b = byte.Parse(stateType);
		if (!global::MathfEx.RangeEqualOn(0, (int)b, 1))
		{
			return false;
		}
		Dictionary<byte, string> dictionary = new Dictionary<byte, string>();
		if (b == 0)
		{
			dictionary[0] = "着衣";
			dictionary[1] = "半脱";
			dictionary[2] = "脱衣";
		}
		else
		{
			dictionary[0] = "着衣";
			dictionary[2] = "脱衣";
		}
		base.dictStateType[clothKind] = dictionary;
		return true;
	}

	// Token: 0x06000FA6 RID: 4006 RVA: 0x00072DE4 File Offset: 0x00070FE4
	public override void RemoveStateKind(int clothKind)
	{
		base.dictStateType.Remove(clothKind);
	}

	// Token: 0x06000FA7 RID: 4007 RVA: 0x00072DF4 File Offset: 0x00070FF4
	public override void SetClothesState(int clothesStateKind, byte state)
	{
		while (state <= 2)
		{
			if (!base.IsStateKind(clothesStateKind))
			{
				this.maleStatusInfo.clothesState[clothesStateKind] = state;
				break;
			}
			if (base.IsStateType(clothesStateKind, state))
			{
				this.maleStatusInfo.clothesState[clothesStateKind] = state;
				break;
			}
			state += 1;
		}
	}

	// Token: 0x06000FA8 RID: 4008 RVA: 0x00072E54 File Offset: 0x00071054
	public override void SetClothesStateAll(byte state)
	{
		int num = Enum.GetNames(typeof(global::CharDefine.ClothesStateKindMale)).Length;
		for (int i = 0; i < num; i++)
		{
			this.SetClothesState(i, state);
		}
	}

	// Token: 0x06000FA9 RID: 4009 RVA: 0x00072E90 File Offset: 0x00071090
	public override void UpdateClothesStateAll()
	{
		int num = Enum.GetNames(typeof(global::CharDefine.ClothesStateKindMale)).Length;
		for (int i = 0; i < num; i++)
		{
			this.SetClothesState(i, this.statusInfo.clothesState[i]);
		}
	}

	// Token: 0x06000FAA RID: 4010 RVA: 0x00072ED8 File Offset: 0x000710D8
	public virtual bool ChangeClothesColor(int clothKind)
	{
		global::CharReference.TagObjKey[] array = new global::CharReference.TagObjKey[]
		{
			global::CharReference.TagObjKey.ObjCTop,
			global::CharReference.TagObjKey.ObjShoes
		};
		List<GameObject> tagInfo = this.chaInfo.GetTagInfo(array[clothKind]);
		global::ColorChange.SetHSColor(tagInfo, this.maleClothesInfo.clothesColor[clothKind], true, true, this.maleClothesInfo.clothesColor2[clothKind], true, true);
		return true;
	}

	// Token: 0x04001117 RID: 4375
	public global::CharMaleFile maleFile;

	// Token: 0x04001118 RID: 4376
	public global::CharFileInfoClothesMale maleClothesInfo;

	// Token: 0x04001119 RID: 4377
	public global::CharFileInfoStatusMale maleStatusInfo;
}
